import {
    instance
} from "@/utils";

/**
 * 查询零元购礼品
 * @param {*} data
 * @returns
 */
export async function getMarketingGiftApi(data) {
    return instance.request({
        url: "/marketing/getMarketingGift",
        method: "post",
        data,
    });
}


/**
 * 查询进度详情
 * @param {*} data
 * @returns
 */
export async function getMarketingRecordApi(data) {
    return instance.request({
        url: "/marketing/getMarketingRecord",
        method: "post", custom: {
            auth: true,
        },
        data,
    });
}

/**
 * 观看广告增加经验值
 * @param {*} data
 * @returns
 */
export async function addEmpiricalByAdvertisingApi(data) {
    return instance.request({
        url: "/marketing/addEmpiricalByAdvertising",
        method: "post", custom: {
            auth: true,
        },
        data,
    });
}


/**
 * 邀请好友助力
 * @param {*} data
 * @returns
 */
export async function getMarketingShareCodeApi(data) {
    return instance.request({
        url: "/marketing/getMarketingShareCode",
        method: "post", custom: {
            auth: true,
        },
        data,
    });
}


/**
 * 零元购规则
 * @param {*} data
 * @returns
 */
export async function getSignRegulationApi(data) {
    return instance.request({
        url: "/marketing/getSignRegulation",
        method: "post", custom: {
            auth: true,
        },
        data,
    });
}
